import request from '@/utils/request'

// 查询赞记录列表
export function listZan(query) {
  return request({
    url: '/cms/zan/list',
    method: 'get',
    params: query
  })
}

// 查询赞记录详细
export function getZan(id) {
  return request({
    url: '/cms/zan/' + id,
    method: 'get'
  })
}

// 新增赞记录
export function addZan(data) {
  return request({
    url: '/cms/zan',
    method: 'post',
    data: data
  })
}

// 修改赞记录
export function updateZan(data) {
  return request({
    url: '/cms/zan',
    method: 'put',
    data: data
  })
}

// 删除赞记录
export function delZan(id) {
  return request({
    url: '/cms/zan/' + id,
    method: 'delete'
  })
}
